createLocalAudioTrack

fun createLocalAudioTrack(context: Context, enabled: Boolean, name: String? = null, audioOptionsBuilder: AudioOptionsBuilder? = null): LocalAudioTrack?

Creates an audio track. Note that the RECORD_AUDIO permission must be granted in order for this operation to succeed. If RECORD_AUDIO is not granted null is returned.

Return

local audio track if successfully added or null if audio track could not be created.

See also

com.twilio.video.LocalAudioTrack

Parameters

context

application context.

enabled

initial state of audio track.

name

audio track name.

audioOptionsBuilder

audio options to be applied to track.